package com.detector.common;

import com.github.pagehelper.PageInfo;

public class DataBean {
	private Pages page;
	private Object data;
	
	public DataBean(Object _object) {
		super();
		if(_object != null && PageInfo.class.getName().equals(_object.getClass().getName())){
			PageInfo pageInfo = (PageInfo)_object;
			this.page = new Pages(pageInfo);
			this.data = pageInfo.getList();
		}else{
			this.data = _object;
		}
	}
	public DataBean() {
		super();
	}
	public DataBean(Pages page, Object data) {
		super();
		this.page = page;
		this.data = data;
	}
	public Pages getPage() {
		return page;
	}
	public void setPage(Pages page) {
		this.page = page;
	}
	public Object getData() {
		return data;
	}
	public void setData(Object data) {
		this.data = data;
	}
	
	
}
